{% load bootstrap3 %}
<!DOCTYPE html>
<html lang="zh-cn">
<head>
    <meta charset="utf-8">
    <meta http-equiv="x-ua-compatible" content="ie=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
    <title>密码重置</title>
    <link rel="stylesheet" href="https://unpkg.com/mobi.css/dist/mobi.min.css">
    <style>
        .errorlist {
            color: red;
        }
        a{
            color: white;
        }
    </style>
</head>
<body>
<div class="flex-center">
    <div class="container">
        <div class="flex-center">
            <div class="unit-1-2 unit-1-on-mobile">
                <h3>密码重置</h3>
                {{ message }}
                <form class="form" action="{% url 'users:reset_password' reset_code %}" method="post">
                    {% csrf_token %}
                    {% if message %}
                        <button class="btn btn-primary "> <a href="{% url 'login' %}">前去登陆</a></button>

                    {% else %}
                        <input type="password" name="newpassword" placeholder="请输入新密码">
                        <input type="password" name="newpassword2" placeholder="请再次输入新密码" >
                        <button type="submit" class="btn btn-primary btn-block">重置</button>
                    {% endif %}
                    <input type="hidden" name="next" value="{{ next }}"/>
                </form>
            </div>
        </div>
    </div>
</div>
</body>
</html>